//该文件专门用于创建整个应用的路由器
import VueRouter from "vue-router";
//应用组件
import home from "@/pages/home.vue";
import login from "@/pages/login.vue";
import H_message from "@/pages/H_message.vue"
import H_News from "@/pages/H_News.vue"

//创建一个路由器 并暴露
//创建router实例对象，去管理一组一组的路由规则
export default new VueRouter({
    routes: [
        {
            path: "/home",
            component: home,
            children: [
                {
                    path: "H_message",
                    component: H_message
                },
                {
                    path: "H_News",
                    component: H_News
                }
            ]
        },
        {
            path: "/login",
            component: login
        },


    ]
})
